@import 'vars';

.outer {
  height: 100%;
  width: 100%;
  background: $border-light-grey;
  border-radius: 3px;
  overflow: hidden;

  &.is-complete {
    .stripes {
      animation: none;
    }
    animation: htf-progress-bar-pulse 2s infinite;
  }
}

.inner-wrapper {
  height: 100%;
  left: -10px;
  position: relative;
  width: calc(100% + 20px);
}

.inner {
  background: rgba($theme-blue, .8);
  height: 100%;
  transition: width .4s ease;
  transform: skewX(-30deg);
}

.stripes {
  transform: skewX(45deg);
  height: 100%;
  width: 100%;
  background-image: linear-gradient(
    -45deg,
    rgba($theme-white, .08) 25%,
    transparent 25%,
    transparent 50%,
    rgba($theme-white, .08) 50%,
    rgba($theme-white, .08) 75%,
    transparent 75%,
    transparent
  );
  background-size: 50px 50px;
  animation: move 4s linear infinite;
}

@keyframes htf-progress-bar-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba($theme-blue, .25);
  }

  70% {
    box-shadow: 0 0 0 8px rgba($theme-blue, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba($theme-blue, 0);
  }
}

@keyframes move {
  0% {
    background-position: 0 0;
  }

  100% {
    background-position: 50px 50px;
  }
}
